<template>
 <div>
  <ul>
      <li v-for="(item,index) in person" :key="index">{{item}}</li>
     
  </ul>
  <button @click="fn">走一走</button>
 </div>
</template>

<script>
 export default {

   data () {
     return {
      person:['帅哥','美女','程序员'],
      a:''

     }
   },
   methods: {
    fn(){
         this.a=this.person[2]
        this.person.pop()
       this.person.unshift(this.a)
       

        
       


    }

   },
 
 }
</script>

<style>

</style>